package bean;

import java.io.Serializable;

import javax.persistence.CascadeType;
import javax.persistence.EmbeddedId;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.OneToMany;
import javax.persistence.OneToOne;
import javax.persistence.Table;

@Entity
@Table(name="telefonos")
public class Telefono implements Serializable{
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	@EmbeddedId
	private TelefonoID uk_telefono;
	
	public Telefono(){}
	
	public static long getSerialVersionUID() {
		return serialVersionUID;
	}

	public void setUk_telefono(TelefonoID uk_telefono) {
		this.uk_telefono = uk_telefono;
	}

	@OneToOne(cascade=CascadeType.ALL)
	@JoinColumn(name="id")
	public TelefonoID getUk_telefono() {
		return uk_telefono;
	}
	

}
